Page({

  /**
   * 页面的初始数据
   */
  data: {
    fbl_address: null,
    fbl_addtime: null,
    fbl_annimalclass: null,
    fbl_annimalsex: null,
    fbl_area: null,
    fbl_birthday: null,
    fbl_city: null,
    fbl_lat: null,
    fbl_lnt: null,
    fbl_mouth: null,
    fbl_pic_min: null,
    fbl_pr: null,
    fbl_qc: null,
    fbl_qq: null,
    fbl_tel: null,
    username: null,
    fbl_vive: null,
    fbl_wx: null,
    fbl_year: null,
    fbl_my: null,
    fbl_jy: null,
    head: null,
    fbl_describe: null,
    topname: '宠物领养小站',
    prepage: 1

  },

  /**
   * 生命周期函数--监听页面加载
   */
  onLoad: function (options) {
    var id = options.id;
    var that = this;
    wx.request({
      url: 'https://www.cwlyz.com/wx/details/detailwantly?id=' + id, //仅为示例，并非真实的接口地址
      data: {
        x: '',
        y: ''
      },
      header: {
        'content-type': 'application/json' // 默认值
      },
      success: function (res) {
        that.setData({ fbl_describe: res.data.data.fbl_describe })
        that.setData({ fbl_address: res.data.data.fbl_address })
        that.setData({ fbl_addtime: res.data.data.fbl_addtime })
        that.setData({ fbl_annimalclass: res.data.data.fbl_annimalclass })
        that.setData({ fbl_annimalsex: res.data.data.fbl_annimalsex })
        that.setData({ fbl_area: res.data.data.fbl_area })
        that.setData({ fbl_birthday: res.data.data.fbl_birthday })
        that.setData({ fbl_city: res.data.data.fbl_city })
        that.setData({ fbl_lat: res.data.data.fbl_lat })
        that.setData({ fbl_lnt: res.data.data.fbl_lnt })
        that.setData({ fbl_mouth: res.data.data.fbl_mouth })
        that.setData({ fbl_pic_min: res.data.data.fbl_pic_min })
        that.setData({ fbl_pr: res.data.data.fbl_pr })
        that.setData({ fbl_qc: res.data.data.fbl_qc })
        that.setData({ fbl_qq: res.data.data.fbl_qq })
        that.setData({ fbl_tel: res.data.data.fbl_tel })
        that.setData({ username: res.data.data.username })
        that.setData({ fbl_vive: res.data.data.fbl_vive })
        that.setData({ fbl_wx: res.data.data.fbl_wx })
        that.setData({ fbl_year: res.data.data.fbl_year })
        that.setData({ fbl_my: res.data.data.fbl_my })
        that.setData({ fbl_jy: res.data.data.fbl_jy })
        that.setData({ head: res.data.data.head })
      }
    })



  },

  /**
   * 生命周期函数--监听页面初次渲染完成
   */
  onReady: function () {

  },

  /**
   * 生命周期函数--监听页面显示
   */
  onShow: function () {

  },

  /**
   * 生命周期函数--监听页面隐藏
   */
  onHide: function () {

  },

  /**
   * 生命周期函数--监听页面卸载
   */
  onUnload: function () {

  },

  /**
   * 页面相关事件处理函数--监听用户下拉动作
   */
  onPullDownRefresh: function () {

  },

  /**
   * 页面上拉触底事件的处理函数
   */
  onReachBottom: function () {

  },

  /**
   * 用户点击右上角分享
   */
  onShareAppMessage: function () {

  },
  phonebind: function (res) {
    wx.makePhoneCall({
      phoneNumber: res.currentTarget.dataset.id //仅为示例，并非真实的电话号码
    })
  },
  clickfuzhi: function (res) {
    var info = res.currentTarget.dataset.info;
    wx.setClipboardData({
      data: info,
      success: function (res) {
        wx.getClipboardData({
          success: function (res) {
            wx.showToast({
              title: '复制成功',
              icon: 'success',
              duration: 2000
            })
          }
        })
      }
    })
  }
})